package com.fowo.api.model.supplier.patrol.task;

import com.alibaba.excel.annotation.ExcelIgnore;
import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import com.alibaba.excel.annotation.write.style.ContentStyle;
import com.alibaba.excel.enums.poi.HorizontalAlignmentEnum;
import com.fowo.api.common.excel.ImageConvert;
import com.fowo.api.sys.entity.SysFile;
import java.util.List;
import javax.validation.constraints.*;
import lombok.Getter;
import lombok.Setter;

/** 供应商巡场任务 导入导出辅助模型 */
@Getter
@Setter
public class SupplierPatrolTaskExcelPo {

  @NotNull(message = "任务编号不能为空")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*任务编号")
  private String patrolTaskId;

  @Size(max = 1024, message = "标题长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "标题")
  private String title;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "采购订单")
  private String purchaseIdPurchaseOrderCode;

  @ExcelIgnore
  @ExcelProperty(value = "采购订单")
  private List<Long> purchaseId;

  @Size(max = 50, message = "供应商长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "供应商")
  private String supplierIdSupplierName;

  @ExcelIgnore
  @ExcelProperty(value = "供应商")
  private List<Long> supplierId;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "状态")
  private String status;

  @NotNull(message = "分配人员不能为空")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "*分配人员")
  private String toUserName;

  @ExcelIgnore
  @ExcelProperty(value = "*分配人员")
  private Long toUser;

  @Size(max = 50, message = "巡场人员长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "巡场人员")
  private String doUserName;

  @ExcelIgnore
  @ExcelProperty(value = "巡场人员")
  private Long doUser;

  @DateTimeFormat("yyyy年MM月dd日")
  @ExcelProperty(value = "巡场时间")
  private java.util.Date doTime;

  @NotNull(message = "截止时间不能为空")
  @DateTimeFormat("yyyy年MM月dd日HH:mm:ss")
  @ExcelProperty(value = "*截止时间")
  private java.util.Date endTime;

  @ExcelProperty(value = "附件", converter = ImageConvert.class)
  private List<SysFile> file;

  @Size(max = 1024, message = "备注长度不能超过20")
  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "备注")
  private String remark;

  @ExcelProperty(value = "及时率")
  private java.math.BigDecimal speedRate;

  @ExcelProperty(value = "良品率")
  private java.math.BigDecimal goodQuantity;

  @ExcelProperty(value = "综合评分")
  private Integer score;

  @ExcelProperty(value = "订单逾期次数")
  private Integer orderOverdueNumber;

  @ExcelProperty(value = "订单逾期天数")
  private Integer orderOverdueDays;

  @ContentStyle(
    horizontalAlignment = HorizontalAlignmentEnum.LEFT,
    dataFormat = 49
  )
  @ExcelProperty(value = "转交人")
  private String forwardUserName;

  @ExcelIgnore
  @ExcelProperty(value = "转交人")
  private Long forwardUser;
}
